@extends('admin.layout.index')
@section('content')
	<div class="mws-panel grid_8">
    	<div class="mws-panel-header">
        	<span>商品修改</span>
        </div>
        <div class="mws-panel-body no-padding">
        	<form class="mws-form" action="/admin/goods/update" method="post" enctype="multipart/form-data">
        		{{ csrf_field() }}
        		<div class="mws-form-inline">
        			<div class="mws-form-row">
        				<label class="mws-form-label">商品名</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="gname" value="{{$data['gname']}}">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">商品类型</label>
        				<div class="mws-form-item">
        					<select name="gpath" id="" style="width:55%">		
								<option value="">--请选择--</option>
								@foreach($fenlei as $k => $v)
								<option value="{{$v['id']}}" >{{$v['name']}}
															
															
								</option>
								@endforeach
							</select>
			
        				</div>
        			</div>
        			
        			<div class="mws-form-row">
        				<label class="mws-form-label">商品数量</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="gsum" value="{{ $data['gsum'] }}">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">发布时间</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="gfbtime" value="{{ $data['gfbtime'] }}">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">商品图片</label>
        				<div class="mws-form-item" style="width:46.5%">
        					<input type="file" class="small" name="gphoto" value="">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">商品大图</label>
        				<div class="mws-form-item" style="width:46.5%">
        					<input type="file" class="small" name="gbigphoto" value="">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">市场价格</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="gscprice" value="{{ $data['gscprice'] }}">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">会员价格</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="ghyprice" value="{{ $data['ghyprice'] }}">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">商品介绍</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="gdetail" value="{{ $data['gdetail'] }}">
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">上架时间</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="starttime" value="{{ date('Y-m-d H:i:s',$data['starttime']) }}" disabled>
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">结束时间</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="endtime" value="{{ date('Y-m-d H:i:s',$data['endtime']) }}" disabled>
        				</div>
        			</div>
        			<div class="mws-form-row">
        				<label class="mws-form-label">购买可得积分</label>
        				<div class="mws-form-item">
        					<input type="text" class="small" name="gjf" value="{{ $data['gjf'] }}">
        				</div>
        			</div>
      
        			
        		</div>
        		<div class="mws-button-row">
                    <input type="hidden" name='id' value="{{$data['gid']}}">
        			<input type="submit" value="修改" class="btn btn-danger">
        			<input type="reset" value="重置" class="btn ">
        		</div>
        	</form>
        </div>    	
    </div>
@endsection